<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
</head>
<body>
<div style="padding: 5px; background: none repeat scroll 0% 0% rgb(239, 239, 239); text-align: right;">
    <a href="javascript:;" class="easyui-linkbutton" plain="true" id="module-post" icon="icon-save">保存</a>|
    <a href="javascript:;" class="easyui-linkbutton" plain="true" icon="icon-cancel" onclick="$('#window').window('close');">退出</a>
</div>
<div style="text-align: right;">
<form id="ModuleForm" method="POST"  action="./index.php?file=catalog&action=add&submit=true">
<table width="100%">
  <tbody>
  <tr>
    <td class="label">分类名称</td>
    <td align="left">
      <input gtbfieldid="7" name="module_name" id="module_name" size="30" type="text">
    </td>
  </tr>
  <tr>
    <td class="label">上级分类</td>
    <td align="left">
      <select gtbfieldid="8" id="module_id" name="pid" style="width: 218px;"></select>
    </td>
  </tr>
  <tr>
    <td class="label">所属分类</td>
    <td align="left">
      <select gtbfieldid="8" id="relevance_id" name="binid" style="width: 218px;"></select>
    </td>
  </tr>
  <tr>
    <td class="label">类型</td>
    <td align="left">
      <select gtbfieldid="8"  name="ispart" style="width: 218px;">
		<option value="1">列表</option>
		<option value="2">栏目</option>
      </select>
    </td>
  </tr>
  <tr>
    <td class="label">关键字</td>
    <td align="left">
      <input gtbfieldid="7" name="keyword" id="keyword" size="30" type="text">
    </td>
  </tr>
  <tr>
  <tr>
    <td class="label">描述</td>
    <td align="left">
      <input gtbfieldid="7" name="description" id="description" size="30" type="text">
    </td>
  </tr>
  <tr>
    <td class="label">生成路径</td>
    <td align="left">
      <input gtbfieldid="7" name="typedir" id="typedir" size="30" type="text">
    </td>
  </tr>
  <tr>
    <td class="label">首页模板</td>
    <td align="left">
      <input gtbfieldid="7" name="tempindex" id="tempindex" size="30" type="text">
    </td>
  </tr>
  <tr>
    <td class="label">列表模板</td>
    <td align="left">
      <input gtbfieldid="7" name="templist" id="templist" size="30" type="text">
    </td>
  </tr>
  <tr>
    <td class="label">文章模板111{$lan}</td>
    <td align="left">
      <input gtbfieldid="7" name="temparticle" id="temparticle" size="30" type="text">
    </td>
  </tr>
  <tr>
</tbody></table>
<script type="text/javascript">
$('#module_name').focus()
$('#module_id').combotree({
    url:"index.php?file=catalog&action=catalogTree&lan=quan&__c=${time()}"
});
$('#relevance_id').combotree({
    url:"index.php?file=catalog&action=catalogTree&lan=quan&__c=${time()}"
});
$('#module_id').combotree('setValue',{id:-1,text:'无选择项'});
$('#relevance_id').combotree('setValue',{id:-1,text:'无选择项'});
$("#module-post").click(function(){
	$('#ModuleForm').submit();
});
$('#ModuleForm').form({
    success:function(data){
    	JSONData = $.evalJSON(data);
    	if(JSONData.status=="error"){
    		$.messager.alert('提示信息', JSONData.msg );
    	}else{
    		window.location.reload();
    	}
    }
});
</script>
</form>
</div>
</body>
</html>